package com.jiaozi.core.table;

import cn.hutool.core.bean.BeanUtil;
import com.baomidou.mybatisplus.core.metadata.IPage;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@AllArgsConstructor
@Data
@Schema(name = "Table分页查询")
@NoArgsConstructor
public class JzTablePageBean<T>  {
    private static final long serialVersionUID = 8545996863226528798L;
    @Schema(description = "分页结果")
    private JzPageBean<T> jzPageData;
    @Schema(description = "表各配置")
    private JzTable jzTable;


    public JzTablePageBean(IPage page,Class tClass){
        this.jzPageData=BeanUtil.copyProperties(page, JzPageBean.class);
        this.jzTable=new JzTable(tClass);
    }




}
